package debashis;

public class Assignment2 {
	public static void main(String[] args)
	{
		//1. Write a program that takes three integer command-line arguments and prints equal if all three are equal, and not equal otherwise.
		int length = args.length;
	    if (length <= 3)
	    {
	      System.out.println("You need to enter three arguments.");
	    }
	    int a=(Integer.parseInt(args[0]));
	    int b=(Integer.parseInt(args[1]));
	    int c=(Integer.parseInt(args[2]));
		  if((a==b)&&(a==c))
		  {
			  System.out.println("Numbers are equal");
		  }
		  else
		  {
			  System.out.println("Numbers are not equal");
		  }
		  
//-------------------------------------------------------------------------------------------		
		//2. Write a program to print table of 13 
		for(int i=0;i<=100;i++)
		{
			System.out.println("13*"+i+"="+13*i);
			
		}
//----------------------------------------------------------------------------------------		  
		
		//3. Print the integers from 1000 to 2000, 5 per line
		for(int i=1000;i<2000;i++)
		{
			int cntr=0;
			int n=0;
		  for(int j=1;j<=5;j++)
		  {
			  
			 n=i+cntr;
			System.out.print(n+" "); 
			cntr=cntr+1;
		  }
		 i=n;
		  System.out.println();
		}
		
//--------------------------------------------------------------------------------------	
	
		//4. Print following structure in Java?
		   /*
		      *
		      ***
		      *****
		      ***
		      *
		  */
		int i;
		for(i=1;i<=5;i++)
		{
			for(int j=1;j<i+1;j++)
			{
				System.out.print("*");
			}
			i=i+1;
			System.out.println();
		}
		for(int k=1;k<=2;k++)
		{
			for(int m=1;m<i-3;m++)
			{
				System.out.print("*");
			}
			i=i-2;
			System.out.println();
		}
//-------------------------------------------------------------------------------------		
		
	}

}
